//
//  JYHomeViewModel.h
//  JYFarm
//
//  Created by 花花 on 2017/10/24.
//  Copyright © 2017年 花花. All rights reserved.
//

#import <Foundation/Foundation.h>

@protocol JYHomeViewModelDelegate <NSObject>

@optional
//获取数据
- (void)homeRightTableRequestDataSuccessWithArray:(NSMutableArray *)dataArray;

//数量
- (void)shopcartAccountFortotalCount:(double)totalCount;


@end


@interface JYHomeViewModel : NSObject

@property(nonatomic,weak) id<JYHomeViewModelDelegate> delegate;


@property(nonatomic,assign)NSInteger count; //保存数量

@property(nonatomic,assign)NSString *selectedId;

@property(nonatomic)NSDictionary *depositObjDic;

//轮播图
- (void)handlerBannerDataWithAreaId:(NSString *)areaId Success:(void(^)(NSArray *lbtArr))success;

//获取商品分类接口 分类信息包含了其子类列表
- (void)handlerCategoryDataWithSuccess:(void(^)(NSArray *resposeObject))success;





//右边数据的处理
- (void)requsetHomeRithtTableList:(NSMutableArray *)array;

//收藏到常用清单
- (void)selectProductAtIndexPath:(NSIndexPath *)indexPath isSelected:(BOOL)isSelected;
//取消收藏
- (void)cancelProductAtIndexPath:(NSIndexPath *)indexPath;




//数量
- (void)changeCountAtIndexPath:(NSIndexPath *)indexPath count:(NSInteger)count;


//批量添加/修改用户购物车
//- (void)adduserShoppingTrolleyList;



//选择左边 刷新右边
- (void)SelectedProducts:(NSString *)selectedId;

@end
